package gstudio.format;

import org.eclipse.jface.action.Action;
import org.eclipse.swt.custom.StyleRange;
import org.eclipse.swt.graphics.Color;
import org.eclipse.swt.graphics.Font;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.ToolItem;

public class Format {
	private String prefix;
	private String postfix;
	private StyleRange styleRange;
	private ToolItem toolItem;
	private int id;
	private String imageName = "";

	private String name = "";
	private int change;
	private int accKey;
	private Font font;
	private Action action;
	private Color background = Display.getDefault().getSystemColor(1);

	private Color foreground = Display.getDefault().getSystemColor(2);

	public ToolItem getToolItem() {
		return this.toolItem;
	}

	public void setToolItem(ToolItem toolItem) {
		this.toolItem = toolItem;
	}

	public int getId() {
		return this.id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public Font getFont() {
		return this.font;
	}

	public void setFont(Font font) {
		this.font = font;
	}

	public int getChange() {
		return this.change;
	}

	public void setChange(int change) {
		this.change = change;
	}

	public int getAccKey() {
		return this.accKey;
	}

	public void setAccKey(int accKey) {
		this.accKey = accKey;
	}

	public Action getAction() {
		return this.action;
	}

	public void setAction(Action action) {
		this.action = action;
	}

	public Color getBackground() {
		return this.background;
	}

	public void setBackground(Color background) {
		this.styleRange.background = background;
		this.background = background;
	}

	public Color getForeground() {
		return this.foreground;
	}

	public void setForeground(Color foreground) {
		this.styleRange.foreground = foreground;
		this.foreground = foreground;
	}

	public String getImageName() {
		return this.imageName;
	}

	public void setImageName(String imageName) {
		this.imageName = imageName;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Format(String pre, String post, StyleRange sr) {
		this.prefix = pre;
		this.postfix = post;
		this.styleRange = sr;
	}

	public String getPrefix() {
		return this.prefix;
	}

	public void setPrefix(String prefix) {
		this.prefix = prefix;
	}

	public String getPostfix() {
		return this.postfix;
	}

	public void setPostfix(String postfix) {
		this.postfix = postfix;
	}

	public StyleRange getStyleRange() {
		return this.styleRange;
	}

	public void setStyleRange(StyleRange styleRange) {
		this.styleRange = styleRange;
	}
}